﻿<?php
	session_start();
	if(empty($_SESSION['user']))
	{
		echo "<script>alert('未登录');</script>";
		echo "<script>window.location.href='../login/login.html'</script>";
	}
	$username=$_SESSION['user'];
	$chkmb_sql="SELECT user.usermail,priv.pri FROM user,priv WHERE user.username='".$username."' AND user.usermail=priv.email";
	$result=mysqli_query($con,$chkmb_sql);
	$row = mysqli_fetch_assoc($result);
	$pri=$row['pri'];
	if($pri>0)
	{
		
	}
	else
	{
		$db->clossConnet();
		echo "<script>alert('权限不够，禁止访问');</script>";
		echo "<script>window.location.href='../index/reflectIndex.php'</script>";
	}
		
?>